<form id="add-form" class="form-horizontal form-ajax" role="form" data-toggle="validator" method="POST" action="">
    {:token()}
    <input type="hidden" class="form-control" id="shop_id" name="row[shop_id]" value="{$shop_id}" data-rule="required;" />
    <div class="form-group">
        <label for="goodsList" class="control-label col-xs-12 col-sm-2">选择商品:</label>
        <div class="col-xs-12 col-sm-8">
            <select id="goodsList" data-rule="required" class="form-control selectpicker" name="row[goods_id]">
                <option value="0">请选择所需要添加的商品</option>
                {foreach name="goods_list" item="vo"}
                <option value="{$vo.id}">{$vo.goods_name}</option>
                {/foreach}
            </select>
        </div>
    </div>
    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">市场价:</label>
        <div class="col-xs-12 col-sm-8">
            <input id="c-market_price" data-rule="required" class="form-control" step="0.01" name="row[market_price]" type="number" value="">
        </div>
    </div>
<!--    <div class="form-group">-->
<!--        <label for="price" class="control-label col-xs-12 col-sm-2">销售价格:</label>-->
<!--        <div class="col-xs-12 col-sm-8">-->
<!--            <input type="text" class="form-control" id="price" name="row[price]" value="" data-rule="required" />-->
<!--        </div>-->
<!--    </div>-->
    <div class="form-group">
        <label for="cost" class="control-label col-xs-12 col-sm-2">成本价:</label>
        <div class="col-xs-12 col-sm-8">
            <input type="text" class="form-control" id="cost" name="row[cost]" value="" data-rule="required;" />
        </div>
    </div>

    <div class="form-group">
        <label class="control-label col-xs-12 col-sm-2">{:__('Status')}:</label>
        <div class="col-xs-12 col-sm-8">
            {:build_radios('row[status]', ['1'=>'上架', '0'=>'下架'])}
        </div>
    </div>
    <div class="form-group hidden layer-footer">
        <label class="control-label col-xs-12 col-sm-2"></label>
        <div class="col-xs-12 col-sm-8">
            <button type="submit" class="btn btn-primary btn-embossed disabled">{:__('OK')}</button>
            <button type="reset" class="btn btn-default btn-embossed">{:__('Reset')}</button>
        </div>
    </div>
</form>
